<!--{template ADMIN_DIRECTORY/tpl/admin_header}-->
<div class="page_title">
    <h1>{$action_arr[$type]['1']}{$_lang['manage']}</h1>
    <div class="tool">
        <a href="index.php?do={$do}&view={$type}">{$action_arr[$type]['1']}{$_lang['list']}</a>
		<a href="javascript:void(0);" class="here">{$action_arr[$type]['1']}{$_lang['manage']}</a>
		<a href="index.php?do=user&view=suggest">建议列表</a>
    </div>
</div>
 <div class="box post">
  <div class="tabcon">
   <div class="title"><h2>{$trans_object[$report_info['obj']]}{$action_arr[$type]['1']}#{$report_id}</h2></div>
    <div class="detail">
     <form action="index.php?do={$do}&view={$view}&type={$type}&report_id={$report_id}" method="post" name="frm" id="frm">
      <table width="100%" border="0" cellspacing="0" cellpadding="0">
       <tr>
         <th scope="row" width="130">{$trans_object[$report_info['obj']]}{$_lang['id']}</th>
       	 <!--<td>#{$report_info['obj_id']}</td>-->
		 <td>#{$report_id}</td>
       </tr>
	   {if $report_info['obj']=='task'||$report_info['obj']=='work'}
	   <tr>
         <th scope="row" width="130">{$_lang['belong_to_task']}</th>
         <td><a href="{$_K['siteurl']}/index.php?do=task&id={$obj_info['origin_id']}" target="_blank">{$obj_info['origin_title']}</a></td>
       </tr>
	   {elseif $report_info['obj']=='task'||$report_info['obj']=='work'}
	   <tr>
         <th scope="row" width="130">{$_lang['belong_to_goods']}</th>
         <td><a href="{$_K['siteurl']}/shop.php?do=service_info&service_id={$obj_info['origin_id']}">{$obj_info['origin_title']}</a></td>
       </tr>
	   {/if}
	  <tr>
       <th scope="row" width="130">{$action_arr[$type]['1']}{$_lang['sponsor']}</th>
       <td>
       		<a href="{$_K['siteurl']}/index.php?do=seller&member_id={$report_info['uid']}" target="_blank">$report_info['username']</a>
			<font color="red">E-mail</font>:{$user_info['email']}&nbsp;||&nbsp;<font color="red">{$_lang['contact_tel']}</font>:{$user_info['phone']}&nbsp;||&nbsp;<font color="red">QQ</font>:{$user_info['qq']}&nbsp;||&nbsp;<font color="red">{$_lang['tel']}</font>:{$user_info['mobile']}
	   </td>
      </tr>
	  {if $report_info['obj']!='kppw21'}
	  <tr>
       <th scope="row" width="130">{$action_arr[$type]['1']}{$_lang['object']}</th>
       <td>
       		<a href="{$_K['siteurl']}/index.php?do=seller&id={$report_info['to_uid']}" target="_blank">$report_info['to_username']</a>
			<font color="red">E-mail</font>:{$to_userinfo['email']}&nbsp;||&nbsp;<font color="red">{$_lang['contact_tel']}</font>:{$to_userinfo['phone']}&nbsp;||&nbsp;<font color="red">QQ</font>:{$to_userinfo['qq']}&nbsp;||&nbsp;<font color="red">{$_lang['tel']}</font>:{$to_userinfo['mobile']}
	   </td>
      </tr>
	  {/if}
	  <tr>
         <th scope="row" width="130">{$_lang['apply']}{$action_arr[$type]['1']}{$_lang['time']}</th>
         <td><!--{date('Y-m-d H:i:s',$report_info['on_time'])}--></td>
      </tr>
	  <tr>
        <th scope="row" width="130">{$_lang['status']}</th>
        <td>{$trans_status[$report_info['report_status']]}</td>
      </tr>
	 <tr>
        <th scope="row" width="130">{$action_arr[$type]['1']}{$_lang['explain']}</th>
        <td><!--{eval echo nl2br($report_info['report_desc'])}--></td>
     </tr>
	 <tr>
        <th scope="row" width="130">{$action_arr[$type]['1']}{$_lang['attachment']}</th>
        <td>
			<!--{eval $filename=substr($report_info['report_file'],strrpos($report_info['report_file'],'/')+1);}-->
			{if $report_info['report_file']}<a href="index.php?do={$do}&view={$type}&ac=download&filename=$filename&filepath={$v['report_file']}">{$filename}</a>{else}{$_lang['no_submit_attachment']}{/if}
		</td>
    </tr>
	<tr id="pass">
       <th scope="row" width="130">{$action_arr[$type]['1']}{$_lang['reply']}</th>
	   <td>
	   	{if $report_info['report_status']=='2'}
	  	 <textarea cols="" rows="7" style="width:360px;" name="op_result[reply]" id="op_result"></textarea>
		{else}
			{$report_info['op_result']}
		{/if}
	   </td>
	</tr>
	<tr style="display:none;" id="nopass">
       <th scope="row" width="130">{$_lang['untenable_reason']}</th>
	   <td>
	   <textarea cols="" rows="7" style="width:360px;" name="op_result[reply]" id="reply"></textarea>
	   </td>
	</tr>
	<tr>
      <th scope="row">&nbsp;</th>
      <td>
          <div class="clearfix padt10">
          	<input type="hidden" name="sbt_op" value="1">
			{if $report_info['report_status']=='2'}
				 <input type="hidden" name="op_result[process_result]" id="process_result">
          		 <input type="hidden" name="op_result[action]" id="action">
          		 <button class="positive primary pill button" type="submit" name="btn_report" value="{$_lang['process']}{$action_arr[$type]['1']}" onclick="return report();"><span class="icon pen"></span>{$_lang['process']}{$action_arr[$type]['1']}</button>
				 <button class="primary negative pill button" type="submit" value="{$action_arr[$type]['1']}{$_lang['untenable']}" onclick="return nopass()"><span class="icon cross "></span>{$action_arr[$type]['1']}{$_lang['untenable']}</button>
			{/if}
          </div>
      </td>
   </tr>
  </tbody>
 </table>
 </form>
 </div>       
</div>
<script type="text/javascript">
	var uid = parseInt($uid);
	function report(){
		$("#pass").show();
		$("#nopass").hide();
		var shtml=$("#op_result").val();		
		if(shtml.length<10){
			art.dialog.alert("{$_lang['reply_not_less_than_ten']}");return false;
		}else{
			art.dialog({
   				title: "{$_lang['comfirm_to_tips']}",
  				content: "{$_lang['confirm_to']}{$action_arr[$type]['1']}{$_lang['record']},{$_lang['reason_for']}:<br>"+shtml,
				icon: 'succeed',
   				yesFn: function(){$("#process_result").val(shtml);$("#action").val('pass');$("#frm").submit()},
				noFn :function(){this.close();return false;}
			});
			return false;
		}
	}
	function nopass(){
		$("#pass").hide();
		$("#nopass").show();
		if($("#nopass").is(":visible")){
			var shtml=$("#reply").val();
			if(shtml.length<20){
				art.dialog.alert("{$_lang['untenable_notice']}");return false;
			}else{	
				art.dialog({
   				title: "{$_lang['comfirm_to_tips']}",
  				content: "{$_lang['comfirm_to_not']}{$action_arr[$type]['1']}{$_lang['record']},{$_lang['reason_for']}:<br>"+shtml,
				icon: 'succeed',
   				yesFn: function(){$("#process_result").val(shtml);$("#action").val('nopass');$("#frm").submit()},
				noFn :function(){this.close();return false;}
			});
			return false;
		  }
	  }
	}
</script>
<!--{template ADMIN_DIRECTORY/tpl/admin_footer}-->